package cn.topcodes.tcsf.app.domain.entity;

import cn.topcodes.tcsf.admin.commons.domain.IdEntity;
import lombok.Data;
import javax.persistence.Column;
import javax.persistence.Table;
import java.util.Date;

/**
 * @author Unicorn
 */
@Data
@Table(name = "t_app_user")
public class AppUser extends IdEntity {

    public static final String FIELD_USERNAME = "username";

    public static final String FIELD_REAL_NAME = "realName";

    public static final String FIELD_PASSWORD = "password";

    public static final String FIELD_TEL = "tel";

    public static final String FIELD_EMAIL = "email";

    public static final String FIELD_GENDER = "gender";

    public static final String FIELD_HEAD_IMG_URL = "headImgUrl";

    public static final String FIELD_ROLE = "role";

    /**
     * 角色类型 - 普通用户
     */
    public static final String ROLE_NORMAL = "Normal";

    /**
     * 角色类型 - 管理员用户
     */
    public static final String ROLE_ADMIN = "Admin";

    /*用户名*/
    private String username;

    /*真实姓名*/
    @Column(name = "real_name")
    private String realName;

    /*密码*/
    private String password;

    /*电话*/
    private String tel;

    /*邮箱*/
    private String email;

    /*性别*/
    private String gender;

    /**
     * 头像地址
     */
    @Column(name = "head_img_url")
    private String headImgUrl;

    /**
     * 角色
     */
    private String role;

}
